Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update theme tier badges #98435

Closed
wants to merge 4 commits into from
Closed

Update theme tier badges #98435

wants to merge 4 commits into from

Conversation

mikachan
Copy link
Member

@mikachan mikachan commented Jan 15, 2025

Related to #95471

Follow-up of #98082

Proposed Changes

  • Add an "Included with plan" badge
  • Style the "free" badge to look the same as the badge in the design picker
  • Fix styling of "Active" badge and options menu (with the updated design these two elements are sat too close to each other)
  • Decide whether the isUpdatedBadgeDesign logic should be removed altogether
  • For partner themes, show "Available on Business" unless you're on the Business or Commerce plans, in which case, just show the price
  • Ensure badges on theme details page are consistent
  • Ensure badges on showcase are consistent

Why are these changes being made?

Implements the designs described in #95471 (comment).

Testing Instructions

Pre-merge Checklist

  • Has the general commit checklist been followed? (PCYsg-hS-p2)
  • Have you written new tests for your changes?
  • Have you tested the feature in Simple (P9HQHe-k8-p2), Atomic (P9HQHe-jW-p2), and self-hosted Jetpack sites (PCYsg-g6b-p2)?
  • Have you checked for TypeScript, React or other console errors?
  • Have you used memoizing on expensive computations? More info in Memoizing with create-selector and Using memoizing selectors and Our Approach to Data
  • Have we added the "[Status] String Freeze" label as soon as any new strings were ready for translation (p4TIVU-5Jq-p2)?
    • For UI changes, have we tested the change in various languages (for example, ES, PT, FR, or DE)? The length of text and words vary significantly between languages.
  • For changes affecting Jetpack: Have we added the "[Status] Needs Privacy Updates" label if this pull request changes what data or activity we track or use (p4TIVU-aUh-p2)?

@matticbot
Copy link
Contributor

This PR modifies the release build for the following Calypso Apps:

For info about this notification, see here: PCYsg-OT6-p2

  • notifications
  • wpcom-block-editor

To test WordPress.com changes, run install-plugin.sh $pluginSlug update/theme-badges on your sandbox.

@matticbot
Copy link
Contributor

Here is how your PR affects size of JS and CSS bundles shipped to the user's browser:

App Entrypoints (~1235 bytes added 📈 [gzipped])

name                   parsed_size           gzip_size
entry-main                  +575 B  (+0.0%)     -107 B  (-0.0%)
entry-login                 -333 B  (-0.0%)     -178 B  (-0.0%)
entry-domains-landing       -333 B  (-0.0%)     -178 B  (-0.1%)
entry-browsehappy           -333 B  (-0.2%)     -178 B  (-0.3%)
entry-subscriptions         -203 B  (-0.0%)    +1159 B  (+0.2%)
entry-stepper               -152 B  (-0.0%)     -173 B  (-0.0%)

Common code that is always downloaded and parsed every time the app is loaded, no matter which route is used.

Sections (~12056 bytes added 📈 [gzipped])

name                                parsed_size           gzip_size
themes                                  -1489 B  (-0.1%)     -881 B  (-0.3%)
site-overview                           -1373 B  (-0.1%)     -144 B  (-0.0%)
update-design-flow                       -632 B  (-0.0%)      +28 B  (+0.0%)
theme                                    -557 B  (-0.1%)     -402 B  (-0.2%)
hundred-year-plan                        -540 B  (-0.3%)      -56 B  (-0.1%)
signup                                   -412 B  (-0.1%)      -30 B  (-0.0%)
site-tools                               +401 B  (+0.0%)     -164 B  (-0.0%)
posts                                    +394 B  (+0.1%)      -20 B  (-0.0%)
staging-site                             +388 B  (+0.0%)     -301 B  (-0.1%)
sites-dashboard                          +388 B  (+0.0%)     -252 B  (-0.1%)
site-settings                            +388 B  (+0.0%)     -194 B  (-0.0%)
site-performance                         +388 B  (+0.0%)     -165 B  (-0.0%)
site-monitoring                          +388 B  (+0.0%)     -120 B  (-0.0%)
site-marketing                           +388 B  (+0.0%)     -283 B  (-0.1%)
site-logs                                +388 B  (+0.0%)     -120 B  (-0.0%)
hosting-features                         +388 B  (+0.0%)     -248 B  (-0.1%)
github-deployments                       +388 B  (+0.0%)     -222 B  (-0.1%)
a8c-for-agencies-sites                   +374 B  (+0.0%)       -7 B  (-0.0%)
write-flow                               +325 B  (+0.0%)     +592 B  (+0.2%)
build-flow                               +325 B  (+0.0%)     +593 B  (+0.2%)
hosting                                  -315 B  (-0.0%)     +247 B  (+0.0%)
a8c-for-agencies-marketplace             +299 B  (+0.0%)     +458 B  (+0.2%)
a8c-for-agencies-purchases               +286 B  (+0.0%)     +874 B  (+0.4%)
reader                                   +282 B  (+0.0%)     -421 B  (-0.1%)
media                                    -245 B  (-0.0%)     -783 B  (-0.2%)
email                                    -230 B  (-0.0%)     +781 B  (+0.4%)
pages                                    +226 B  (+0.0%)       -7 B  (-0.0%)
link-in-bio-tld-flow                     -219 B  (-0.0%)     +106 B  (+0.0%)
a8c-for-agencies-team                    +219 B  (+0.0%)     -329 B  (-0.1%)
a8c-for-agencies-referrals               +219 B  (+0.0%)     -329 B  (-0.1%)
a8c-for-agencies-overview                +219 B  (+0.0%)     -329 B  (-0.1%)
a8c-for-agencies-migrations              +219 B  (+0.0%)     -329 B  (-0.1%)
a8c-for-agencies-client                  +219 B  (+0.0%)     -329 B  (-0.1%)
settings-podcast                         -216 B  (-0.0%)      -25 B  (-0.0%)
posts-custom                             +213 B  (+0.0%)      +82 B  (+0.0%)
security                                 +206 B  (+0.0%)      +24 B  (+0.0%)
performance-profiler                     +206 B  (+0.1%)      +25 B  (+0.0%)
backup                                   +199 B  (+0.0%)      +93 B  (+0.0%)
plans                                    +196 B  (+0.0%)     +239 B  (+0.1%)
scan                                     -188 B  (-0.0%)      +18 B  (+0.0%)
gutenberg-editor                         +178 B  (+0.0%)     -357 B  (-0.2%)
a8c-for-agencies-partner-directory       +170 B  (+0.0%)     +472 B  (+0.3%)
settings                                 -152 B  (-0.0%)     +126 B  (+0.0%)
domains                                  +140 B  (+0.0%)     +503 B  (+0.1%)
home                                     +131 B  (+0.0%)     +312 B  (+0.1%)
jetpack-cloud                            +112 B  (+0.0%)       +0 B
start-writing-flow                       +108 B  (+0.3%)      -11 B  (-0.1%)
preview                                  +108 B  (+0.0%)      +45 B  (+0.0%)
onboarding-flow                          -108 B  (-0.4%)      -23 B  (-0.3%)
new-hosted-site-flow                     -108 B  (-0.1%)      -22 B  (-0.0%)
hundred-year-domain                      -108 B  (-0.0%)      -33 B  (-0.1%)
stats                                    +105 B  (+0.0%)      -17 B  (-0.0%)
export                                   +105 B  (+0.0%)      +13 B  (+0.0%)
marketplace                              +104 B  (+0.0%)      +36 B  (+0.0%)
jetpack-cloud-settings                   -104 B  (-0.0%)      +68 B  (+0.0%)
transferring-hosted-site-flow            +103 B  (+0.0%)      +17 B  (+0.0%)
settings-performance                     +103 B  (+0.0%)      +31 B  (+0.0%)
plugin-bundle-flow                       +103 B  (+0.0%)      +23 B  (+0.0%)
jetpack-app                              +103 B  (+0.0%)      +27 B  (+0.0%)
a8c-for-agencies                         +103 B  (+0.1%)     +199 B  (+0.5%)
plugins                                  +100 B  (+0.0%)     -878 B  (-0.1%)
jetpack-cloud-overview                    -94 B  (-0.0%)     +268 B  (+0.2%)
a8c-for-agencies-settings                 +93 B  (+0.0%)     +386 B  (+0.6%)
a8c-for-agencies-plugins                  +93 B  (+0.0%)     +386 B  (+0.7%)
a8c-for-agencies-agency-tier              +93 B  (+0.0%)     +383 B  (+0.5%)
import                                    +92 B  (+0.0%)       -5 B  (-0.0%)
devdocs                                   +88 B  (+0.0%)       +9 B  (+0.0%)
newsletter-post-setup-flow                -84 B  (-0.0%)      -55 B  (-0.1%)
link-in-bio-post-setup-flow               -84 B  (-0.0%)      -55 B  (-0.1%)
copy-site-flow                            -77 B  (-0.0%)     -393 B  (-0.1%)
reblogging-flow                           -72 B  (-0.9%)      -15 B  (-0.7%)
jetpack-cloud-partner-portal              -71 B  (-0.0%)     -108 B  (-0.0%)
people                                    +64 B  (+0.0%)     +125 B  (+0.0%)
activity                                  -58 B  (-0.0%)     -190 B  (-0.1%)
jetpack-cloud-agency-sites-v2             +55 B  (+0.0%)     -633 B  (-0.1%)
jetpack-cloud-plugin-management           +48 B  (+0.0%)     -816 B  (-0.1%)
promote-post-i2                           +42 B  (+0.0%)     +422 B  (+0.2%)
a8c-for-agencies-signup                   -39 B  (-0.0%)       +3 B  (+0.0%)
jetpack-cloud-agency-signup               +26 B  (+0.0%)     +104 B  (+0.4%)
site-purchases                            +21 B  (+0.0%)     +354 B  (+0.1%)
comments                                  +21 B  (+0.0%)      -24 B  (-0.0%)
patterns                                  -13 B  (-0.0%)       +2 B  (+0.0%)
import-hosted-site-flow                   -13 B  (-0.0%)      -35 B  (-0.0%)
checkout                                  -13 B  (-0.0%)     -341 B  (-0.1%)
purchases                                 +12 B  (+0.0%)      -37 B  (-0.0%)

Sections contain code specific for a given set of routes. Is downloaded and parsed only when a particular route is navigated to.

Async-loaded Components (~8381 bytes removed 📉 [gzipped])

name                                                                              parsed_size           gzip_size
async-load-design-blocks                                                              -1776 B  (-0.1%)     -814 B  (-0.1%)
async-load-signup-steps-theme-selection                                               -1698 B  (-0.5%)     -568 B  (-0.5%)
async-load-calypso-my-sites-checkout-modal                                             +183 B  (+0.0%)     +247 B  (+0.1%)
async-load-calypso-jetpack-cloud-sections-sidebar-navigation-manage-selected-...       +177 B  (+0.2%)     +264 B  (+0.7%)
async-load-signup-steps-domains                                                        -170 B  (-0.0%)     -463 B  (-0.2%)
async-load-calypso-post-editor-media-modal                                             -144 B  (-0.0%)     -488 B  (-0.1%)
async-load-signup-steps-design-picker                                                  +108 B  (+0.1%)      +15 B  (+0.1%)
async-load-calypso-my-sites-stats-stats-post-detail                                    +108 B  (+0.3%)      +43 B  (+0.4%)
async-load-calypso-my-sites-site-settings-seo-settings-form                            +108 B  (+0.0%)      +45 B  (+0.1%)
async-load-signup-steps-woocommerce-install-step-store-address                         -103 B  (-0.1%)       -9 B  (-0.0%)
async-load-signup-steps-woocommerce-install-step-business-info                         +103 B  (+0.1%)      +25 B  (+0.1%)
async-load-signup-steps-plans-theme-preselected                                        +103 B  (+0.0%)      +21 B  (+0.0%)
async-load-signup-steps-plans                                                          +103 B  (+0.0%)      +21 B  (+0.0%)
async-load-quick-language-switcher                                                     +103 B  (+0.1%)      +26 B  (+0.1%)
async-load-masterbar-launchpad-navigator                                               +103 B  (+0.1%)      +16 B  (+0.1%)
async-load-calypso-lib-account-settings-helper                                         +103 B  (+0.1%)      +22 B  (+0.0%)
async-load-automattic-whats-new                                                        +103 B  (+0.3%)      +16 B  (+0.1%)
async-load-design-wordpress-components-gallery                                          +93 B  (+0.0%)     +800 B  (+0.4%)
async-load-calypso-layout-community-translator                                          -84 B  (-0.3%)      -38 B  (-0.5%)
async-load-calypso-components-web-preview-component                                     -77 B  (-0.0%)     +401 B  (+0.3%)
async-load-calypso-post-editor-editor-media-modal                                       -51 B  (-0.0%)      -39 B  (-0.0%)
async-load-design                                                                       -39 B  (-0.0%)     -245 B  (-0.1%)
async-load-comment-block-editor                                                         -13 B  (-0.0%)       -5 B  (-0.0%)
async-load-calypso-blocks-editor-checkout-modal                                         -13 B  (-0.0%)      -79 B  (-0.0%)
async-load-automattic-global-styles-src-components-global-styles-variations             -13 B  (-0.0%)      -33 B  (-0.0%)

React components that are loaded lazily, when a certain part of UI is displayed for the first time.

Legend

What is parsed and gzip size?

Parsed Size: Uncompressed size of the JS and CSS files. This much code needs to be parsed and stored in memory.
Gzip Size: Compressed size of the JS and CSS files. This much data needs to be downloaded over network.

Generated by performance advisor bot at iscalypsofastyet.com.

@jeryj
Copy link
Contributor

jeryj commented Jan 15, 2025

It looks like the "Available on ____" badge work and removing tooltips has already been done behind the isGoalsAtFrontExperiment flag in #97655. If we're set on shipping this design, I think a lot of the work will just be to remove the isGoalsAtFrontExperiement.

@fditrapani - Do you have more info on that experiment and if it's ready to launch to everyone?

@mikachan
Copy link
Member Author

Closing in favour of #98451.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants